package com.kmxd.ams.client.system.vo;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.*;
import com.alibaba.excel.enums.poi.HorizontalAlignmentEnum;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * 消息接收信息表
 *
 * @author nickbi
 * @since 2023-04-11
 */
@Data
@ColumnWidth(15)
@HeadRowHeight(15)
@ContentRowHeight(15)
@HeadStyle
@HeadFontStyle(fontHeightInPoints = 12)
@ContentStyle(horizontalAlignment = HorizontalAlignmentEnum.CENTER)
@ContentFontStyle(fontHeightInPoints = 10)
@ExcelIgnoreUnannotated
@Schema(description = "消息接收信息表对象")
public class SysMessageInfoListVO implements Serializable {

  private static final long serialVersionUID = 1L;

  @Schema(description = "主键id")
  @JsonSerialize(using = ToStringSerializer.class)
  @ExcelProperty(value = "主键id")
  private Long id;

  @Schema(description = "消息id")
  @JsonSerialize(using = ToStringSerializer.class)
  @ExcelProperty(value = "消息id")
  private Long messageId;

  @Schema(description = "接收用户,角色,部门id")
  @JsonSerialize(using = ToStringSerializer.class)
  @ExcelProperty(value = "接收用户,角色,部门id")
  private Long receiveId;

  @Schema(description = "状态0未读,0待办理、1已读,已处理")
  @ExcelProperty(value = "状态0未读,0待办理、1已读,已处理")
  private Integer status;

  @Schema(description = "创建人")
  @JsonSerialize(using = ToStringSerializer.class)
  @ExcelProperty(value = "创建人")
  private Long createBy;

  @Schema(description = "创建时间")
  @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
  @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  @ColumnWidth(20)
  @ExcelProperty(value = "创建时间")
  private Date createTime;

  @Schema(description = "更新人")
  @JsonSerialize(using = ToStringSerializer.class)
  @ExcelProperty(value = "更新人")
  private Long updateBy;

  @Schema(description = "更新时间")
  @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
  @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  @ColumnWidth(20)
  @ExcelProperty(value = "更新时间")
  private Date updateTime;

  @Schema(description = "备注")
  @ExcelProperty(value = "备注")
  private String remarks;
}
